﻿#region

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BuXiaChu.OrderDishes.Model;
using BuXiaChu.OrderDishes.DAL;

#endregion

namespace BuXiaChu.OrderDishes.BLL
{
    public class RolesManager
    {
        /// <summary>
        /// Insert Or Update
        /// </summary>
        public static bool Save(RolesModel obj)
        {
            return RolesDAL.Save(obj);
        }

        public static RolesModel GetByRolesId(Guid roleId)
        {
            return RolesDAL.GetByRolesId(roleId);
        }

        public static List<RolesModel> GetApplicationId(Guid ApplicationId)
        {
            return RolesDAL.GetApplicationId(ApplicationId);
        }

        public static List<RolesModel> GetAll()
        {
            return RolesDAL.GetAll();
        }

        public static List<RolesModel> GetListBySysUserId(int sysUserId)
        {
            return RolesDAL.GetListBySysUserId(sysUserId);
        }

        public static bool AddRolesToSysUser(Guid roleId,int sysUserId)
        {
            return RolesDAL.AddRolesToSysUser(roleId,sysUserId);
        }

        public static Dictionary<int, List<RolesModel>> GetRoleListBySysUserIds(string sysUserIds)
        {
            return RolesDAL.GetRoleListBySysUserIds(sysUserIds);
        }
    }
}
